﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Share/Index.Master" Inherits="System.Web.Mvc.ViewPage<dynamic>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="MainContent" runat="server">

<%
    string uid = Request["uid"].ToString();    
%>
<script language="javascript" type="text/javascript">
    $(function () {
        $("#outExcel").click(function () {
            var _param = "/librarybook/userbooklistExce.html?uid=<%=uid %>";
            window.location.href = _param;
        });
    });
</script>
 
  <table id="tableExcel" cellspacing="0" style="width:100%;">
  <caption style="text-align:center;">
  <input type="button" id="outExcel" value="导入到Excel" class="btn1" />
 </caption>
             <tr>
             <th>ISBN</th>
             <th>书名</th>
             <th>译名</th>
             <th>图书状态</th>
             <th>适读年龄</th>
             <th>级别</th>
             <th>类型</th>
             <th>借阅时间</th>
             <th>归还时间</th>
             <th>家长备注</th>
             </tr>
             <tbody id="usercardlist">
             
             <% 
                 DAL.Service.IUserInfoService user = new DAL.Service.Impl.UserInfoServiceImpl();
                 IList li = user.userBooksList(int.Parse(uid));
                 foreach (Hashtable tb in li)
                 {
                     
              %>
                <tr>
                <td><%=tb["lbd_isbn"]%></td>
                <td><%=tb["lb_bookName"]%></td>
                <td><%=tb["lb_translatedName"]%></td>
                <td><%=Enum.GetName(typeof(DAL.Enums.bookState), int.Parse(tb["lb_state"].ToString()))%></td>
                <td><%=Enum.GetName(typeof(DAL.Enums.bookforAge), int.Parse(tb["lb_forAge"].ToString())).Replace("_","")%></td>
                <td><%=Enum.GetName(typeof(DAL.Enums.boollevel), int.Parse(tb["lb_level"].ToString()))%></td>
                <td><%=Enum.GetName(typeof(DAL.Enums.bookType), int.Parse(tb["lb_bookType"].ToString()))%></td>
                <td><%=tb["lbi_time"]%></td>
                <td><%=tb["returntime"]%></td>
                <td><%=tb["lbi_appraisal"]%></td>
                </tr>
              <%   
                 }
              %>
             
             </tbody>
             </table>

</asp:Content>
